package com.example.demospring5.primary.lifecircle;

import org.springframework.beans.factory.InitializingBean;
import org.springframework.stereotype.Component;

@Component
public class InitBean implements InitializingBean {

    /**
     * <bean id="exampleInitBean" class="examples.ExampleBean" init-method="init"/>
     */
    @Override
    public void afterPropertiesSet() {
        // do some initialization work
        System.out.println("do some initialization work");
    }
}